var _EsdDynamicTransformationFunction = function($){
/**
 * 命名空间定义
 */
var _EsdDynamicTransformationScript = {};
_EsdDynamicTransformationScript.navBlock = {}; // 定义区域跳转类
_EsdDynamicTransformationScript.navBlock.selector = {};
/**
 * 文本链接 a
 */
//保证所有a标签都有href
$("a").each(function(){

	var aHref = this.href;
	if( aHref=="" || aHref==undefined ){
			$(this).attr("href","javascript:void(0)");
	}
	
	//给a标签加title
	var aTitle = this.title;
	var aText = this.text;
	
	if( aTitle=="" || aTitle==undefined ){
		if( aText!="" || aText!=undefined ){
			$(this).attr("title",$.trim(aText));
		}
	}
	
});

//搜索
$("#zhx_btn1").attr("title","请输入搜索内容");
$("#zhx_btn1").attr("placeholder","请输入搜索内容");
$("#zhx_btn3").attr("title","搜索");

/**
 * 图片处理片段
 */

/**
 * 图片处理片段
 */

//右侧边栏iframe图片
_EsdDynamicTransformationScript.rightImgInterval = setInterval(function(){	
	if($($(".right-rainbow iframe")[0].contentWindow.document).find("img:eq(0)")!=undefined){
		clearInterval(_EsdDynamicTransformationScript.rightImgInterval);
		$($(".right-rainbow iframe")[0].contentWindow.document).find("img:eq(0)").attr("title","十四五规划专栏");
		$($(".right-rainbow iframe")[0].contentWindow.document).find("img:eq(1)").attr("title","资源产品价格");
		$($(".right-rainbow iframe")[0].contentWindow.document).find("img:eq(2)").attr("title","吉林省投资项目在线审批监管平台");
		$($(".right-rainbow iframe")[0].contentWindow.document).find("img:eq(3)").attr("title","吉林省发改委的微博和微信二维码");
		$($(".right-rainbow iframe")[0].contentWindow.document).find("img:eq(4)").attr("title","吉林省产教融合型企业建设培育");
		$($(".right-rainbow iframe")[0].contentWindow.document).find("img:eq(5)").attr("title","吉林省物流统计网上直报系统");
	}	
}, 500);

//footer的iframe
_EsdDynamicTransformationScript.footerImgInterval = setInterval(function(){	
	if($($("iframe:last")[0].contentWindow.document).find("img:eq(0)")!=undefined){
		clearInterval(_EsdDynamicTransformationScript.footerImgInterval);
		$($("iframe:last")[0].contentWindow.document).find("img:eq(0)").attr("title","党政机关");
		$($("iframe:last")[0].contentWindow.document).find("img:eq(1)").attr("title","政府网站找错");
	}	
}, 500);
 
 
$('img[src="./qt/gzdt/201912/W020191225472504256282.jpg"]').attr('title','省发展改革委党组理论中心组专题学习党的十九届四中全会精神').attr('alt','省发展改革委党组理论中心组专题学习党的十九届四中全会精神');
$('img[src="./tpxw/201912/W020191224521027299444.jpg"]').attr('title','吉林省建立健全城乡融合发展体制机制和政策体系新闻发布会').attr('alt','吉林省建立健全城乡融合发展体制机制和政策体系新闻发布会');
$('img[src="./qt/sypc/201907/W020190722588291833927.png"]').attr('title','不忘初心牢记使命主题教育').attr('alt','不忘初心牢记使命主题教育');
$('img[src="./jjyxtb/201705/W020181112551552912199.jpg"]').attr('title','2017年全省居民消费价格总指数变化趋势图').attr('alt','2017年全省居民消费价格总指数变化趋势图');
$('img[src="./images/zhx_jlsfgw20170104_oneimg4.png"]').attr('title','委属单位').attr('alt','委属单位');
$('img[src="./zl/dcaqzlzxxd/images/P020191217343852734558.jpg"]').attr('title','冬春安全治理专项行动和安全生产集中整治').attr('alt','冬春安全治理专项行动和安全生产集中整治');
$('img[src="./W020191224521021648360.jpg"]').attr('title','吉林省建立健全城乡融合发展体制机制和政策体系新闻发布会').attr('alt','吉林省建立健全城乡融合发展体制机制和政策体系新闻发布会');
$('img[src="./images/zhx_jlsfgw20170104_logo.png"]').attr('title','吉林省发展和改革委员会').attr('alt','吉林省发展和改革委员会');$('img[src="./images/zhx_jlsfgw20170104_threeimg77.png"]').attr('title','收起').attr('alt','收起');
$('img[src="./images/zhx_jlsfgw20170104_threeimg7.jpg"]').attr('title','收起').attr('alt','收起');$('img[src="./images/jlsfgwzyhbjxsimgzhx_20170831.jpg"]').attr('title','中央环保督察进行时').attr('alt','中央环保督察进行时');
$('img[src="./qt/gzdt/201912/W020191206515902328376.jpg"]').attr('title','省发展改革委组织召开高速公路货车通行费计费方式调整听证会').attr('alt','省发展改革委组织召开高速公路货车通行费计费方式调整听证会');
$('img[src="./images/zhx_jlsfgw20170104_oneimg2.png"]').attr('title','领导分工').attr('alt','领导分工');
$('img[src="./xwfbzx/xwfb/201912/W020191205399001760345.jpg"]').attr('title','吉林省投资项目在线审批监管平台评为全国三星级综合示范平台').attr('alt','吉林省投资项目在线审批监管平台评为全国三星级综合示范平台');
$('img[src="./images/zhx_jlsfgw20170104_oneimg1.png"]').attr('title','机构职能').attr('alt','机构职能');
$('img[src="./tpxw/201911/W020191125573083699769.jpg"]').attr('title','吉林省加强燃气安全管理工作新闻发布会').attr('alt','吉林省加强燃气安全管理工作新闻发布会');
$('img[src="./qt/syzcpc/images/P020191210563373722718.jpg"]').attr('title','吉林省项目中心公开电话0431-88905243').attr('alt','吉林省项目中心公开电话0431-88905243');
$('img[src="./tpxw/201912/W020191202352750101224.jpg"]').attr('title','省发展改革委举办第二期“处长讲堂”').attr('alt','省发展改革委举办第二期“处长讲堂”');
$('img[src="./images/zhx_jlsfgw20170104_threeimg1.png"]').attr('title','加载更多').attr('alt','加载更多');
$('img[src="./images/zhx_jlsfgw20170104_oneimg3.png"]').attr('title','内设机构').attr('alt','内设机构');$('img[src="./images/zhx_jlsfgw20170104_threeimg11.png"]').attr('title','加载更多').attr('alt','加载更多');
$('img[src="./qt/gzdt/201912/W020191214398863867007.jpg"]').attr('title','省委常委、常务副省长吴靖平赴省项目中心调研').attr('alt','省委常委、常务副省长吴靖平赴省项目中心调研');
$('img[src="./jjyxtb/201705/W020181112551554228966.jpg"]').attr('title','2017年全省地区生产总值图表').attr('alt','2017年全省地区生产总值图表');

//img
$("img").each(function(){
	//给图片加alt/title
	var imgAlt = this.alt,
		imgTitle = this.title,
		imgSrc = this.src,
		parentText = this.parentElement.text;

	if(this.alt=="" || this.alt==undefined){
		if(imgTitle!="" && imgTitle!=undefined){
			$(this).attr("alt",imgTitle);
		}else if(parentText!="" && parentText!=undefined){
			$(this).attr("alt",parentText);
		}
	}
	if(this.title=="" || this.title==undefined){
		if(imgAlt!="" && imgAlt!=undefined){
			$(this).attr("title",imgAlt);
		}else if(parentText!="" && parentText!=undefined){
			$(this).attr("title",parentText);
		}
	}
})

$("img").each(function(){
	if( (this.alt=="" && this.title=="")||(this.alt==undefined && this.title==undefined) ){
		$(this).attr("title","图片");
		$(this).attr("alt","图片");
	}
})
/**
 * 共通头部
 */
/**
 * 主导航
 */
/**
 * 网站所有幻灯片，轮播
 */

//首页
if(location.href=="http://jldrc.jl.gov.cn/" || location.href=="http://jldrc.jl.gov.cn/index.html"){
	
	

	//轮播
	//轮播,右下角原点--鼠标移动触发情况

	//轮播：只获取轮播中一个a标签。
	//以文字a标签为主，图片a标签尽量不要，title不稳定

	//轮播前的标签
	_EsdDynamicTransformationScript.esdTagFrontNum1 = $("#zhx_btn3");

	//文字A标签
	_EsdDynamicTransformationScript.esdTagANum1 = $(".zhx_nav_lunbo_title h3:eq(0) a");
	_EsdDynamicTransformationScript.esdTagANum2 = $(".zhx_nav_lunbo_title h3:eq(1) a");
	_EsdDynamicTransformationScript.esdTagANum3 = $(".zhx_nav_lunbo_title h3:eq(2) a");
	_EsdDynamicTransformationScript.esdTagANum4 = $(".zhx_nav_lunbo_title h3:eq(3) a");
	_EsdDynamicTransformationScript.esdTagANum5 = $(".zhx_nav_lunbo_title h3:eq(4) a");

	//原点
	_EsdDynamicTransformationScript.esdTagCircleNum1 = $(".zhx_nav_lunbo_control ul li:eq(0)");
	_EsdDynamicTransformationScript.esdTagCircleNum2 = $(".zhx_nav_lunbo_control ul li:eq(1)");
	_EsdDynamicTransformationScript.esdTagCircleNum3 = $(".zhx_nav_lunbo_control ul li:eq(2)");
	_EsdDynamicTransformationScript.esdTagCircleNum4 = $(".zhx_nav_lunbo_control ul li:eq(3)");
	_EsdDynamicTransformationScript.esdTagCircleNum5 = $(".zhx_nav_lunbo_control ul li:eq(4)");

	//轮播后的标签
	_EsdDynamicTransformationScript.esdTagAfterNum1 = $(".zhx_nav_li1 .zhx_nav_li1_div .zhx_nav_h3 a");


		//轮播前的焦点
		_EsdDynamicTransformationScript.esdTagFrontNum1.focus(function (e) {
			$(document).bind("keydown.keydown_0", function (e) {
				if(e.shiftKey&&e.keyCode==9){
					
				}else if (e.keyCode == 9) {
					_EsdDynamicTransformationScript.esdTagCircleNum1.mouseover();
					_EsdDynamicTransformationScript.esdTagANum1.focus();
					console.log(document.activeElement);
					return false;
				}
			});
		});
		_EsdDynamicTransformationScript.esdTagFrontNum1.blur(function () {
			$(document).unbind("keydown.keydown_0");
		});
		
		

		//第一块
		_EsdDynamicTransformationScript.esdTagANum1.focus(function (e) {
			
			_EsdDynamicTransformationScript.esdTagCircleNum1.mouseover();
			$(document).bind("keydown.keydown_1", function (e) {
				if(e.shiftKey&&e.keyCode==9){
					
				}else if (e.keyCode == 9) {
					_EsdDynamicTransformationScript.esdTagCircleNum2.mouseover();
					_EsdDynamicTransformationScript.esdTagANum2.focus();
					console.log(document.activeElement);
					return false;
				}
			});

		});
		_EsdDynamicTransformationScript.esdTagANum1.blur(function () {
			$(document).unbind("keydown.keydown_1");
		});

		//第二块
		_EsdDynamicTransformationScript.esdTagANum2.focus(function (e) {
			
			_EsdDynamicTransformationScript.esdTagCircleNum2.mouseover();
			$(document).bind("keydown.keydown_2", function (e) {
				if(e.shiftKey&&e.keyCode==9){
					_EsdDynamicTransformationScript.esdTagCircleNum1.mouseover();
					_EsdDynamicTransformationScript.esdTagANum1.focus();
					return false;
				}else if (e.keyCode == 9) {
					_EsdDynamicTransformationScript.esdTagCircleNum3.mouseover();
					_EsdDynamicTransformationScript.esdTagANum3.focus();
					console.log(document.activeElement);
					return false;
				}
			});

		});
		_EsdDynamicTransformationScript.esdTagANum2.blur(function () {
			$(document).unbind("keydown.keydown_2");
		});
		
		//第三块
		_EsdDynamicTransformationScript.esdTagANum3.focus(function (e) {
			
			_EsdDynamicTransformationScript.esdTagCircleNum3.mouseover();
			$(document).bind("keydown.keydown_3", function (e) {
				if(e.shiftKey&&e.keyCode==9){
					_EsdDynamicTransformationScript.esdTagCircleNum2.mouseover();
					_EsdDynamicTransformationScript.esdTagANum2.focus();
					return false;
				}else if (e.keyCode == 9) {
					_EsdDynamicTransformationScript.esdTagCircleNum4.mouseover();
					_EsdDynamicTransformationScript.esdTagANum4.focus();
					console.log(document.activeElement);
					return false;
				}
			});

		});
		_EsdDynamicTransformationScript.esdTagANum3.blur(function () {
			$(document).unbind("keydown.keydown_3");
		});
		
		//第四块
		_EsdDynamicTransformationScript.esdTagANum4.focus(function (e) {
			_EsdDynamicTransformationScript.esdTagCircleNum4.mouseover();
			$(document).bind("keydown.keydown_4", function (e) {
				if(e.shiftKey&&e.keyCode==9){
					_EsdDynamicTransformationScript.esdTagCircleNum3.mouseover();
					_EsdDynamicTransformationScript.esdTagANum3.focus();
					return false;
				}else if (e.keyCode == 9) {
					_EsdDynamicTransformationScript.esdTagCircleNum5.mouseover();
					_EsdDynamicTransformationScript.esdTagANum5.focus();
					console.log(document.activeElement);
					return false;
				}
			});

		});
		_EsdDynamicTransformationScript.esdTagANum4.blur(function () {
			$(document).unbind("keydown.keydown_4");
		});
		
		//第五块
		_EsdDynamicTransformationScript.esdTagANum5.focus(function (e) {
			
			_EsdDynamicTransformationScript.esdTagCircleNum5.mouseover();
			$(document).bind("keydown.keydown_5", function (e) {
				if(e.shiftKey&&e.keyCode==9){
					_EsdDynamicTransformationScript.esdTagCircleNum4.mouseover();
					_EsdDynamicTransformationScript.esdTagANum4.focus();
					return false;
				}else if (e.keyCode == 9) {
				
				}
			});

		});
		_EsdDynamicTransformationScript.esdTagANum5.blur(function () {
			$(document).unbind("keydown.keydown_5");
		});
		
		//轮播后的焦点
		_EsdDynamicTransformationScript.esdTagAfterNum1.focus(function (e) {
			
			$(document).bind("keydown.keydown_6", function (e) {
				if(e.shiftKey&&e.keyCode==9){
					_EsdDynamicTransformationScript.esdTagCircleNum5.mouseover();
					_EsdDynamicTransformationScript.esdTagANum5.focus();
					return false;
				}else if (e.keyCode == 9) {
					
				}
			});

		});
		_EsdDynamicTransformationScript.esdTagAfterNum1.blur(function () {
			$(document).unbind("keydown.keydown_6");
		});
	
	
	
}





/**
 * 二级页
 */

// -------------------------------二级页------------------------------------
if(location.href=="http://jldrc.jl.gov.cn/zmhd/ldxx/"){
//领导信箱

	_EsdDynamicTransformationScript.iframeldxx0 = document.getElementsByTagName("iframe")[0];
	_EsdDynamicTransformationScript.num1 = _EsdDynamicTransformationScript.iframeldxx0.contentWindow.document.getElementsByClassName("xdTextBox")[0];
	_EsdDynamicTransformationScript.num2 = _EsdDynamicTransformationScript.iframeldxx0.contentWindow.document.getElementsByClassName("xdTextBox")[1];
	_EsdDynamicTransformationScript.num3 = _EsdDynamicTransformationScript.iframeldxx0.contentWindow.document.getElementsByClassName("xdTextBox")[2];
	_EsdDynamicTransformationScript.num4 = _EsdDynamicTransformationScript.iframeldxx0.contentWindow.document.getElementsByClassName("xdTextBox")[3];
	
	_EsdDynamicTransformationScript.num5 = _EsdDynamicTransformationScript.iframeldxx0.contentWindow.document.getElementsByClassName("xdRichTextBox")[0];
	
	_EsdDynamicTransformationScript.num6 = _EsdDynamicTransformationScript.iframeldxx0.contentWindow.document.getElementById("SubmitButton");
	_EsdDynamicTransformationScript.num7 = _EsdDynamicTransformationScript.iframeldxx0.contentWindow.document.getElementById("ResetButton");
	
	$(_EsdDynamicTransformationScript.num1).attr("title","收信人");
	$(_EsdDynamicTransformationScript.num2).attr("title","信件主题");
	$(_EsdDynamicTransformationScript.num3).attr("title","您的姓名");
	$(_EsdDynamicTransformationScript.num4).attr("title","联系方式");
	$(_EsdDynamicTransformationScript.num5).attr("title","信件内容");	
	$(_EsdDynamicTransformationScript.num6).attr("title","提交");	
	$(_EsdDynamicTransformationScript.num7).attr("title","重置");	
	
	$(_EsdDynamicTransformationScript.num1).attr("placeholder","收信人");
	$(_EsdDynamicTransformationScript.num2).attr("placeholder","信件主题");
	$(_EsdDynamicTransformationScript.num3).attr("placeholder","您的姓名");
	$(_EsdDynamicTransformationScript.num4).attr("placeholder","联系方式");
	$(_EsdDynamicTransformationScript.num5).attr("placeholder","信件内容");	
	

	
}

if(location.href=="http://jldrc.jl.gov.cn/zmhd/jyxc/"){
//建言献策
	var inputIframe = document.getElementsByTagName("iframe")[0].contentWindow.document;
	$(inputIframe).find("#frmData input:eq(0)").attr({placeholder:"姓名",title:"姓名"});
	$(inputIframe).find("#frmData input:eq(1)").attr({placeholder:"联系方式",title:"联系方式"});
	$(inputIframe).find("#frmData textarea:eq(0)").attr({placeholder:"建言标题",title:"建言标题"});
	$(inputIframe).find("#frmData .xdRichTextBox").attr({placeholder:"建言内容",title:"建言内容"});
	
	$(inputIframe).find("#SubmitButton").attr("title","提交");	
	$(inputIframe).find("#ResetButton").attr("title","重置");	


}		
		
if(location.href=="http://jldrc.jl.gov.cn/zmhd/jyxc/"){
//举报投诉
	var inputIframe = document.getElementsByTagName("iframe")[0].contentWindow.document;
	$(inputIframe).find("#frmData input:eq(0)").attr({placeholder:"您的姓名",title:"您的姓名"});
	$(inputIframe).find("#frmData input:eq(1)").attr({placeholder:"您的电话",title:"您的电话"});
	$(inputIframe).find("#frmData input:eq(2)").attr({placeholder:"举报或投诉标题",title:"举报或投诉标题"});
	$(inputIframe).find("#frmData .xdRichTextBox").attr({placeholder:"举报或投诉内容",title:"举报或投诉内容"});
	
	$(inputIframe).find("#SubmitButton").attr("title","提交");	
	$(inputIframe).find("#ResetButton").attr("title","重置");	


}	
///**
// * 主页js
// */




//首页
if(location.href=="http://jldrc.jl.gov.cn/" || location.href=="http://jldrc.jl.gov.cn/index.html"){

															//头--------------对应的内容--------整个，头+内容---------第几个-----内容中的第一个a-----------上一个的所有---------上一个的内容第一个a
_EsdDynamicTransformationScript.navTabChange = function (focusObjSelector, listObjSelector, mouseEventObjSelector, keyDownNum, listElementsSelector, prevMouseEventObjSelector, prevListObjsSelector) {
    var keydownName = "keydown.navKeydown_" + keyDownNum;
    var keydownName2 = keydownName + "_1";
    $(focusObjSelector).focus(function () {
		if ($(listObjSelector).is(":hidden")) {
			$(focusObjSelector).mouseover();
		}
        $(this).bind(keydownName, function (e) {
            if (e.shiftKey && e.keyCode == 9) {
                if (prevMouseEventObjSelector != "") {
					$(focusObjSelector).mouseout();
					$(prevMouseEventObjSelector + " a:eq(0)").mouseover();
					$(prevListObjsSelector).last().focus();
					$(this).unbind(keydownName);  // 失去焦点时解绑有问题在这解绑一次
					return false;
                } else{
					$(focusObjSelector).mouseout();
					$(this).unbind(keydownName);  // 失去焦点时解绑有问题在这解绑一次
				}
            } else if (e.keyCode == 9) {
				
            }
        });

    });
    $(focusObjSelector).blur(function () {
        $(this).unbind(keydownName);
    });
	
    $(listElementsSelector).last().focus(function () {
        $(this).bind(keydownName2, function (e) {
            if (e.shiftKey && e.keyCode == 9) {
			
            } else if (e.keyCode == 9) {
                $(focusObjSelector).mouseout();
            }
        });
    });
    $(listElementsSelector).last().blur(function () {
        $(this).unbind(keydownName2);
    });
};


_EsdDynamicTransformationScript.navArray = new Array();

// 导航第一个栏目
_EsdDynamicTransformationScript.nav1 = {}
_EsdDynamicTransformationScript.nav1.focusObjSelector = ".zhx_nav_box .zhx_nav .zhx_nav_li1 a:eq(0)"; //按tab聚焦元素的选择器
_EsdDynamicTransformationScript.nav1.listObjSelector = ".zhx_nav_box .zhx_nav .zhx_nav_li1 .zhx_nav_box1"; // 按tab聚焦后展示列表选择器 用来判断列表是否已经展示  
_EsdDynamicTransformationScript.nav1.mouseEventObjSelector = ".zhx_nav_box .zhx_nav .zhx_nav_li1"; // 按tab聚焦后展示的列表所使用的鼠标事件绑定的元素 
_EsdDynamicTransformationScript.nav1.keyDownNum = 1; // keydown事件标识  最好不要重复 
_EsdDynamicTransformationScript.nav1.listElementsSelector = ".zhx_nav_box .zhx_nav .zhx_nav_li1 .zhx_nav_box1 a"; // 按tab聚焦后 展示列表中a链接的选择器(展示列表中第一个a标签)
_EsdDynamicTransformationScript.nav1.prevMouseEventObjSelector = ""; //上一个相邻的鼠标事件(mouseover)的元素 如果是向上切换没有就使用空字符串""
_EsdDynamicTransformationScript.nav1.prevListObjsSelector = ""; // 上一个相邻的展示列表中a链接的选择器

_EsdDynamicTransformationScript.navArray.push(_EsdDynamicTransformationScript.nav1);  // 放到数组里循环

// 导航第二个栏目
_EsdDynamicTransformationScript.nav2 = {}
_EsdDynamicTransformationScript.nav2.focusObjSelector = ".zhx_nav_box .zhx_nav .zhx_nav_li2 a:eq(0)"; //按tab聚焦元素的选择器
_EsdDynamicTransformationScript.nav2.listObjSelector = ".zhx_nav_box .zhx_nav .zhx_nav_li2 .zhx_nav_box2"; // 按tab聚焦后展示列表选择器 用来判断列表是否已经展示
_EsdDynamicTransformationScript.nav2.mouseEventObjSelector = ".zhx_nav_box .zhx_nav .zhx_nav_li2"; // 按tab聚焦后展示的列表所使用的鼠标事件绑定的元素 
_EsdDynamicTransformationScript.nav2.keyDownNum = 2; // keydown事件标识  最好不要重复
_EsdDynamicTransformationScript.nav2.listElementsSelector = ".zhx_nav_box .zhx_nav .zhx_nav_li2 .zhx_nav_box2 a"; // 按tab聚焦后 展示列表中a链接的选择器
_EsdDynamicTransformationScript.nav2.prevMouseEventObjSelector = ".zhx_nav_box .zhx_nav .zhx_nav_li1"; //上一个相邻的鼠标事件(mouseover)的元素 如果是向上切换没有就使用空字符串""
_EsdDynamicTransformationScript.nav2.prevListObjsSelector = ".zhx_nav_box .zhx_nav .zhx_nav_li1 .zhx_nav_box1 a"; // 上一个相邻的展示列表中a链接的选择器

_EsdDynamicTransformationScript.navArray.push(_EsdDynamicTransformationScript.nav2);  // 放到数组里循环

// 导航第三个栏目
_EsdDynamicTransformationScript.nav3 = {}
_EsdDynamicTransformationScript.nav3.focusObjSelector = ".zhx_nav_box .zhx_nav .zhx_nav_li3 a:eq(0)"; //按tab聚焦元素的选择器
_EsdDynamicTransformationScript.nav3.listObjSelector = ".zhx_nav_box .zhx_nav .zhx_nav_li3 .zhx_nav_box3"; // 按tab聚焦后展示列表选择器 用来判断列表是否已经展示
_EsdDynamicTransformationScript.nav3.mouseEventObjSelector = ".zhx_nav_box .zhx_nav .zhx_nav_li3"; // 按tab聚焦后展示的列表所使用的鼠标事件绑定的元素 
_EsdDynamicTransformationScript.nav3.keyDownNum = 3; // keydown事件标识  最好不要重复
_EsdDynamicTransformationScript.nav3.listElementsSelector = ".zhx_nav_box .zhx_nav .zhx_nav_li3 .zhx_nav_box3 .zhx_nav_box3_iframe ul a"; // 按tab聚焦后 展示列表中a链接的选择器
_EsdDynamicTransformationScript.nav3.prevMouseEventObjSelector = ".zhx_nav_box .zhx_nav .zhx_nav_li2"; //上一个相邻的鼠标事件(mouseover)的元素 如果是向上切换没有就使用空字符串""
_EsdDynamicTransformationScript.nav3.prevListObjsSelector = ".zhx_nav_box .zhx_nav .zhx_nav_li2 .zhx_nav_box2 a"; // 上一个相邻的展示列表中a链接的选择器

_EsdDynamicTransformationScript.navArray.push(_EsdDynamicTransformationScript.nav3);  // 放到数组里循环

// 导航第四个栏目
_EsdDynamicTransformationScript.nav4 = {}
_EsdDynamicTransformationScript.nav4.focusObjSelector = ".zhx_nav_box .zhx_nav .zhx_nav_li4 a:eq(0)"; //按tab聚焦元素的选择器
_EsdDynamicTransformationScript.nav4.listObjSelector = ".zhx_nav_box .zhx_nav .zhx_nav_li4 .zhx_nav_box4"; // 按tab聚焦后展示列表选择器 用来判断列表是否已经展示
_EsdDynamicTransformationScript.nav4.mouseEventObjSelector = ".zhx_nav_box .zhx_nav .zhx_nav_li4"; // 按tab聚焦后展示的列表所使用的鼠标事件绑定的元素 
_EsdDynamicTransformationScript.nav4.keyDownNum = 4; // keydown事件标识  最好不要重复
_EsdDynamicTransformationScript.nav4.listElementsSelector = ".zhx_nav_box .zhx_nav .zhx_nav_li4 .zhx_nav_box4 a"; // 按tab聚焦后 展示列表中a链接的选择器
_EsdDynamicTransformationScript.nav4.prevMouseEventObjSelector = ".zhx_nav_box .zhx_nav .zhx_nav_li3"; //上一个相邻的鼠标事件(mouseover)的元素 如果是向上切换没有就使用空字符串""
_EsdDynamicTransformationScript.nav4.prevListObjsSelector = ".zhx_nav_box .zhx_nav .zhx_nav_li3 .zhx_nav_box3 .zhx_nav_box3_iframe ul a"; // 上一个相邻的展示列表中a链接的选择器

_EsdDynamicTransformationScript.navArray.push(_EsdDynamicTransformationScript.nav4);  // 放到数组里循环


for(var i=0; i<_EsdDynamicTransformationScript.navArray.length; i++){

	_EsdDynamicTransformationScript.navTabChange(_EsdDynamicTransformationScript.navArray[i].focusObjSelector, _EsdDynamicTransformationScript.navArray[i].listObjSelector, 
		_EsdDynamicTransformationScript.navArray[i].mouseEventObjSelector, _EsdDynamicTransformationScript.navArray[i].keyDownNum, _EsdDynamicTransformationScript.navArray[i].listElementsSelector,
		_EsdDynamicTransformationScript.navArray[i].prevMouseEventObjSelector, _EsdDynamicTransformationScript.navArray[i].prevListObjsSelector);
}





//将iframe所包含的a链接数 第一个a元素 最后一个a元素赋值给第一个参数的js对象
_EsdDynamicTransformationScript.getIframeInfos = function(jsObj,iframeObj){
	jsObj.aLink_num = iframeObj.contentWindow.document.getElementsByTagName("a").length;
	jsObj.first_aLink = iframeObj.contentWindow.document.getElementsByTagName("a")[0];
	jsObj.last_aLink = iframeObj.contentWindow.document.getElementsByTagName("a")[jsObj.aLink_num-1];
	jsObj.self = iframeObj;
};

//声明iframe操作对象
_EsdDynamicTransformationScript.iframe1 = {};
_EsdDynamicTransformationScript.iframe2 = {};

_EsdDynamicTransformationScript.iframeElement1 = document.getElementsByTagName("iframe")[2];   // 需要修改 这里的iframe获取
_EsdDynamicTransformationScript.iframeElement2 = document.getElementsByTagName("iframe")[3];   // 需要修改 这里的iframe获取


//选项卡标签 jquery对象
_EsdDynamicTransformationScript.iframeTab1 = $(".zhx_two_zyxxzczz .zhx_two_zyxxzczz_bottom .zhx_two_zyxxzczz_bottom_top ul li:eq(0) a");  // 需要修改
																																			// 这里的tab获取
_EsdDynamicTransformationScript.iframeTab2 = $(".zhx_two_zyxxzczz .zhx_two_zyxxzczz_bottom .zhx_two_zyxxzczz_bottom_top ul li:eq(1) a");  // 需要修改
																																			// 这里的tab获取



//判断iframe是否有效
if((_EsdDynamicTransformationScript.iframeElement1!=undefined) && (_EsdDynamicTransformationScript.iframeElement2!=undefined)){

	// 当iframe都加载完毕后执行代码 使用setInterval
	_EsdDynamicTransformationScript.iframeInterval = setInterval(function(){	
		
		if((_EsdDynamicTransformationScript.iframeElement1.contentWindow.document.getElementsByTagName("a")[0]!=undefined) 
				&& (_EsdDynamicTransformationScript.iframeElement2.contentWindow.document.getElementsByTagName("a")[0]!=undefined) ){
			clearInterval(_EsdDynamicTransformationScript.iframeInterval);

//通过方法赋值
_EsdDynamicTransformationScript.getIframeInfos(_EsdDynamicTransformationScript.iframe1,_EsdDynamicTransformationScript.iframeElement1);  // 需要修改
																																		// 这里的iframe获取
_EsdDynamicTransformationScript.getIframeInfos(_EsdDynamicTransformationScript.iframe2,_EsdDynamicTransformationScript.iframeElement2);  // 需要修改
																																		// 这里的iframe获取

		
		// 第一个标签 切换
		_EsdDynamicTransformationScript.iframeTab1.focus(function (e) {
		 console.log("tab1获取到焦点");
		 e = $(this).mouseover();
		 $(document).bind("keydown.iframeKeydown_1", function (e) {
		     if (e.shiftKey && e.keyCode == 9) {
					console.log("tab1向回切换");
		         _EsdDynamicTransformationScript.iframeTab1.trigger("blur");
		     } else if (e.keyCode == 9) {
		         console.log("tab1继续切换到iframe上");
		         _EsdDynamicTransformationScript.iframeTab1.trigger("blur");
		         $(_EsdDynamicTransformationScript.iframe1.self).focus();
		         console.log(document.activeElement);
		         return false;
		     }
		 });
		});
		_EsdDynamicTransformationScript.iframeTab1.blur(function () {
		 $(document).unbind("keydown.iframeKeydown_1");
		});
		
		// 第一个标签的第一个链接
		$(_EsdDynamicTransformationScript.iframe1.first_aLink).focus(function () {
		 console.log("第一个iframe的第一条获得焦点");
		 $(_EsdDynamicTransformationScript.iframe1.self.contentWindow.document).bind("keydown.iframeKeydown_first1", function (e) {
		     if (e.shiftKey && e.keyCode == 9) {
					console.log("第一个iframe的第一条向上切换");
		         $(document).trigger("blur");
		         _EsdDynamicTransformationScript.iframeTab1.focus();
		         return false;
		     } else if (e.keyCode == 9) {
					console.log("第一个iframe的第一条继续切换");
		     }
		 });
		});
		$(_EsdDynamicTransformationScript.iframe1.first_aLink).blur(function () {
		 $(_EsdDynamicTransformationScript.iframe1.self.contentWindow.document).unbind("keydown.iframeKeydown_first1");
		});
		
		// 第一个标签的最后一个链接
		$(_EsdDynamicTransformationScript.iframe1.last_aLink).focus(function () {
		 console.log("第一个iframe的最后一条获得焦点");
		 $(_EsdDynamicTransformationScript.iframe1.self.contentWindow.document).bind("keydown.iframeKeydown_first1", function (e) {
		     if (e.shiftKey && e.keyCode == 9) {
					console.log("第一个iframe的最后一条向上切换");
		     } else if (e.keyCode == 9) {
					console.log("第一个iframe的最后一条继续切换 到下一个标签");
					 $(document).trigger("blur");
		         _EsdDynamicTransformationScript.iframeTab2.focus();
		         return false;
		     }
		 });
		});
		$(_EsdDynamicTransformationScript.iframe1.last_aLink).blur(function () {
		 $(_EsdDynamicTransformationScript.iframe1.self.contentWindow.document).unbind("keydown.iframeKeydown_first1");
		});
		
		
		// 第二个标签切换
		_EsdDynamicTransformationScript.iframeTab2.focus(function (e) {
		 console.log("tab2获取到焦点");
		 e = $(this).mouseover();
		 $(document).bind("keydown.iframeKeydown_2", function (e) {
		     if (e.shiftKey && e.keyCode == 9) {
					console.log("第二个标签向回切换 到第一个标签的最后一条");
		         _EsdDynamicTransformationScript.iframeTab2.trigger("blur");
		         _EsdDynamicTransformationScript.iframeTab1.mouseover();
		         $(_EsdDynamicTransformationScript.iframe1.last_aLink).focus();
		         return false;
		     } else if (e.keyCode == 9) {
		         _EsdDynamicTransformationScript.iframeTab2.trigger("blur");
		         $(_EsdDynamicTransformationScript.iframe2.self).focus();
		         console.log(document.activeElement);
		         return false;
		     }
		 });
		
		});
		_EsdDynamicTransformationScript.iframeTab2.blur(function () {
		 $(document).unbind("keydown.iframeKeydown_2");
		});

		}
		
	}, 500);

}




	

//第一部分
	//各个选项名称对应的内容数量
_EsdDynamicTransformationScript.num1 = $("#zhx_nav_box4 #zhx_nav_box4_bottom ul:eq(0) li").length-1;
_EsdDynamicTransformationScript.num2 = $("#zhx_nav_box4 #zhx_nav_box4_bottom ul:eq(1) li").length-1;
	
	//各个选项名称
_EsdDynamicTransformationScript.esdTagNum1 = $("#zhx_nav_box4 .zhx_nav_box4_top ul li:eq(0) a");
_EsdDynamicTransformationScript.esdTagNum2 = $("#zhx_nav_box4 .zhx_nav_box4_top ul li:eq(1) a");
	
	//各个选项中的第一个内容
_EsdDynamicTransformationScript.esdTagNum1Content1 = $("#zhx_nav_box4_bottom ul:eq(0) li:eq(0) a:eq(0)");
_EsdDynamicTransformationScript.esdTagNum2Content1 = $("#zhx_nav_box4_bottom ul:eq(1) li:eq(0) a:eq(0)");
	
	//各个选项中的最后一个内容
_EsdDynamicTransformationScript.esdTagNum1ContentN = $("#zhx_nav_box4_bottom ul:eq(0) li:eq("+_EsdDynamicTransformationScript.num1+") a:eq(1)");
_EsdDynamicTransformationScript.esdTagNum2ContentN = $("#zhx_nav_box4_bottom ul:eq(1) li:eq("+_EsdDynamicTransformationScript.num2+") a:eq(1)");
	
	//第一块
	_EsdDynamicTransformationScript.esdTagNum1.focus(function (e) {
		
		e = $(this).mouseover();
		$(document).bind("keydown.keydown_1", function (e) {
			if(e.shiftKey&&e.keyCode==9){
				
			}else if (e.keyCode == 9) {
				_EsdDynamicTransformationScript.esdTagNum1Content1.focus();
				console.log(document.activeElement);
				return false;
			}
		});

	});
	_EsdDynamicTransformationScript.esdTagNum1.blur(function () {
		
		$(document).unbind("keydown.keydown_1");
	});

	_EsdDynamicTransformationScript.esdTagNum1Content1.focus(function () {
		$(document).bind("keydown.keydown_s1", function (e) {
			if (e.shiftKey && e.keyCode == 9) {
				_EsdDynamicTransformationScript.esdTagNum1.focus();
				return false;
			}
		});
	});
	_EsdDynamicTransformationScript.esdTagNum1Content1.blur(function () {
		$(document).unbind("keydown.keydown_s1");
	});

	_EsdDynamicTransformationScript.esdTagNum1ContentN.focus(function () {
		$(document).bind("keydown.keydown_e1", function (e) {
			if(e.shiftKey&&e.keyCode==9){
				
			}else if (e.keyCode == 9) {
				_EsdDynamicTransformationScript.esdTagNum2.mouseover();
				_EsdDynamicTransformationScript.esdTagNum2.focus();
				return false;
			}
		});
	});
	_EsdDynamicTransformationScript.esdTagNum1ContentN.blur(function () {
		$(document).unbind("keydown.keydown_e1");
	});
	
	//第二块
	_EsdDynamicTransformationScript.esdTagNum2.focus(function (e) {
		console.log("进入第二块");
		e = $(this).mouseover();
		$(document).bind("keydown.keydown_2", function (e) {
			if(e.shiftKey&&e.keyCode==9){
				_EsdDynamicTransformationScript.esdTagNum1.mouseover();
				_EsdDynamicTransformationScript.esdTagNum1ContentN.focus();
				return false;
			}else if (e.keyCode == 9) {
				_EsdDynamicTransformationScript.esdTagNum2Content1.focus();
				console.log(document.activeElement);
				return false;
			}
		});

	});
	_EsdDynamicTransformationScript.esdTagNum2.blur(function () {
		$(document).unbind("keydown.keydown_2");
	});
	
	
//第二部分
	//各个选项名称对应的内容数量
_EsdDynamicTransformationScript.num4 = 4;
_EsdDynamicTransformationScript.num5 = $(".zhx_one_pic .zhx_one_pic_bottom ul #video_news dl dd ").length-1;
	
	//各个选项名称
_EsdDynamicTransformationScript.esd2TagNum1 = $(".zhx_one_box .zhx_one_pic .zhx_one_pic_top ul li:eq(0) a");
_EsdDynamicTransformationScript.esd2TagNum2 = $(".zhx_one_box .zhx_one_pic .zhx_one_pic_top ul li:eq(1) a");
	
	//各个选项中的第一个内容
_EsdDynamicTransformationScript.esd2TagNum1Content1 = $(".zhx_one_pic .zhx_one_pic_bottom ul .pic_news .wrapper .pic_news_title h3:eq(0) a");
_EsdDynamicTransformationScript.esd2TagNum2Content1 = $(".zhx_one_pic .zhx_one_pic_bottom ul #video_news dl dd:eq(0) a:eq(0)");
	
	//各个选项中的最后一个内容
_EsdDynamicTransformationScript.esd2TagNum1ContentN = $(".zhx_one_pic .zhx_one_pic_bottom ul .pic_news .wrapper .pic_news_title h3:eq("+_EsdDynamicTransformationScript.num4+") a");
_EsdDynamicTransformationScript.esd2TagNum2ContentN = $(".zhx_one_pic .zhx_one_pic_bottom ul #video_news dl dd:eq("+_EsdDynamicTransformationScript.num5+") a:eq(1)");
	
	//第一块
	_EsdDynamicTransformationScript.esd2TagNum1.focus(function (e) {
		
		e = $(this).mouseover();
		$(document).bind("keydown.keydown_1", function (e) {
			if(e.shiftKey&&e.keyCode==9){
				$(_EsdDynamicTransformationScript.nav4.focusObjSelector).mouseover();
				_EsdDynamicTransformationScript.esdTagNum2.mouseover();
				$(_EsdDynamicTransformationScript.nav4.listElementsSelector).last().focus();
				return false;
			}else if (e.keyCode == 9) {
				$(".zhx_one_pic .zhx_one_pic_bottom ul .pic_news .wrapper ul li:eq(0)").mouseover();
				_EsdDynamicTransformationScript.esd2TagNum1Content1.focus();
				console.log(document.activeElement);
				return false;
			}
		});

	});
	_EsdDynamicTransformationScript.esd2TagNum1.blur(function () {
		$(document).unbind("keydown.keydown_1");
	});

	_EsdDynamicTransformationScript.esd2TagNum1Content1.focus(function () {
		$(document).bind("keydown.keydown_s1", function (e) {
			if (e.shiftKey && e.keyCode == 9) {
				_EsdDynamicTransformationScript.esd2TagNum1.focus();
				return false;
			}else if (e.keyCode == 9) {
				$(".zhx_one_pic .zhx_one_pic_bottom ul .pic_news .wrapper ul li:eq(1)").mouseover();
				$(".zhx_one_pic .zhx_one_pic_bottom ul .pic_news .wrapper .pic_news_title h3:eq(1) a").focus();
				return false;
			}
		});
	});
	_EsdDynamicTransformationScript.esd2TagNum1Content1.blur(function () {
		$(document).unbind("keydown.keydown_s1");
	});

	$(".zhx_one_pic .zhx_one_pic_bottom ul .pic_news .wrapper .pic_news_title h3:eq(1) a").focus(function () {
		$(document).bind("keydown.keydown_s2", function (e) {
			if (e.shiftKey && e.keyCode == 9) {
				$(".zhx_one_pic .zhx_one_pic_bottom ul .pic_news .wrapper ul li:eq(0)").mouseover();
				$(".zhx_one_pic .zhx_one_pic_bottom ul .pic_news .wrapper .pic_news_title h3:eq(0) a").focus();
				return false;
			}else if (e.keyCode == 9) {
				$(".zhx_one_pic .zhx_one_pic_bottom ul .pic_news .wrapper ul li:eq(2)").mouseover();
				$(".zhx_one_pic .zhx_one_pic_bottom ul .pic_news .wrapper .pic_news_title h3:eq(2) a").focus();
				return false;
			}
		});
	});
	$(".zhx_one_pic .zhx_one_pic_bottom ul .pic_news .wrapper .pic_news_title h3:eq(1) a").blur(function () {
		$(document).unbind("keydown.keydown_s2");
	});

	$(".zhx_one_pic .zhx_one_pic_bottom ul .pic_news .wrapper .pic_news_title h3:eq(2) a").focus(function () {
		$(document).bind("keydown.keydown_s3", function (e) {
			if (e.shiftKey && e.keyCode == 9) {
				$(".zhx_one_pic .zhx_one_pic_bottom ul .pic_news .wrapper ul li:eq(1)").mouseover();
				$(".zhx_one_pic .zhx_one_pic_bottom ul .pic_news .wrapper .pic_news_title h3:eq(1) a").focus();
				return false;
			}else if (e.keyCode == 9) {
				$(".zhx_one_pic .zhx_one_pic_bottom ul .pic_news .wrapper ul li:eq(3)").mouseover();
				$(".zhx_one_pic .zhx_one_pic_bottom ul .pic_news .wrapper .pic_news_title h3:eq(3) a").focus();
				return false;
			}
		});
	});
	$(".zhx_one_pic .zhx_one_pic_bottom ul .pic_news .wrapper .pic_news_title h3:eq(2) a").blur(function () {
		$(document).unbind("keydown.keydown_s3");
	});

	$(".zhx_one_pic .zhx_one_pic_bottom ul .pic_news .wrapper .pic_news_title h3:eq(3) a").focus(function () {
		$(document).bind("keydown.keydown_s4", function (e) {
			if (e.shiftKey && e.keyCode == 9) {
				$(".zhx_one_pic .zhx_one_pic_bottom ul .pic_news .wrapper ul li:eq(2)").mouseover();
				$(".zhx_one_pic .zhx_one_pic_bottom ul .pic_news .wrapper .pic_news_title h3:eq(2) a").focus();
				return false;
			}else if (e.keyCode == 9) {
				$(".zhx_one_pic .zhx_one_pic_bottom ul .pic_news .wrapper ul li:eq(4)").mouseover();
				$(".zhx_one_pic .zhx_one_pic_bottom ul .pic_news .wrapper .pic_news_title h3:eq(4) a").focus();
				return false;
			}
		});
	});
	$(".zhx_one_pic .zhx_one_pic_bottom ul .pic_news .wrapper .pic_news_title h3:eq(3) a").blur(function () {
		$(document).unbind("keydown.keydown_s4");
	});

	_EsdDynamicTransformationScript.esd2TagNum1ContentN.focus(function () {
		$(document).bind("keydown.keydown_e1", function (e) {
			if(e.shiftKey&&e.keyCode==9){
				$(".zhx_one_pic .zhx_one_pic_bottom ul .pic_news .wrapper ul li:eq(3)").mouseover();
				$(".zhx_one_pic .zhx_one_pic_bottom ul .pic_news .wrapper .pic_news_title h3:eq(3) a").focus();
				return false;
			}else if (e.keyCode == 9) {
				_EsdDynamicTransformationScript.esd2TagNum2.focus();
				return false;
			}
		});
	});
	_EsdDynamicTransformationScript.esd2TagNum1ContentN.blur(function () {
		$(document).unbind("keydown.keydown_e1");
	});
	
	//第二块
	_EsdDynamicTransformationScript.esd2TagNum2.focus(function (e) {
		e = $(this).mouseover();
		$(document).bind("keydown.keydown_2", function (e) {
			if(e.shiftKey&&e.keyCode==9){
				_EsdDynamicTransformationScript.esd2TagNum1.mouseover();
				$(".zhx_one_pic .zhx_one_pic_bottom ul .pic_news .wrapper ul li:eq(4)").mouseover();
				$(".zhx_one_pic .zhx_one_pic_bottom ul .pic_news .wrapper .pic_news_title h3:eq(4) a").focus();
				return false;
			}else if (e.keyCode == 9) {
				_EsdDynamicTransformationScript.esd2TagNum2Content1.focus();
				console.log(document.activeElement);
				return false;
			}
		});

	});
	_EsdDynamicTransformationScript.esd2TagNum2.blur(function () {
		$(document).unbind("keydown.keydown_2");
	});
	
//第三部分
	//各个选项名称对应的内容数量
_EsdDynamicTransformationScript.num6 = $("#zhx_one_job_bottom ul:eq(0) li").length-1;
_EsdDynamicTransformationScript.num7 = $("#zhx_one_job_bottom ul:eq(1) li").length-1;
_EsdDynamicTransformationScript.num8 = $("#zhx_one_job_bottom ul:eq(2) li").length-1;
_EsdDynamicTransformationScript.num9 = $("#zhx_one_job_bottom ul:eq(3) li").length-1;
_EsdDynamicTransformationScript.num10 = $("#zhx_one_job_bottom ul:eq(4) li").length-1;
	
	//各个选项名称
_EsdDynamicTransformationScript.esd3TagNum1 = $(".zhx_one_job .zhx_one_job_top ul li:eq(0) a");
_EsdDynamicTransformationScript.esd3TagNum2 = $(".zhx_one_job .zhx_one_job_top ul li:eq(1) a");
_EsdDynamicTransformationScript.esd3TagNum3 = $(".zhx_one_job .zhx_one_job_top ul li:eq(2) a");
_EsdDynamicTransformationScript.esd3TagNum4 = $(".zhx_one_job .zhx_one_job_top ul li:eq(3) a");
_EsdDynamicTransformationScript.esd3TagNum5 = $(".zhx_one_job .zhx_one_job_top ul li:eq(4) a");
	
	//各个选项中的第一个内容
_EsdDynamicTransformationScript.esd3TagNum1Content1 = $("#zhx_one_job_bottom ul:eq(0) li:eq(0) a:eq(0)");
_EsdDynamicTransformationScript.esd3TagNum2Content1 = $("#zhx_one_job_bottom ul:eq(1) li:eq(0) a:eq(0)");
_EsdDynamicTransformationScript.esd3TagNum3Content1 = $("#zhx_one_job_bottom ul:eq(2) li:eq(0) a:eq(0)");
_EsdDynamicTransformationScript.esd3TagNum4Content1 = $("#zhx_one_job_bottom ul:eq(3) li:eq(0) a:eq(0)");
_EsdDynamicTransformationScript.esd3TagNum5Content1 = $("#zhx_one_job_bottom ul:eq(4) li:eq(0) a:eq(0)");
	
	//各个选项中的最后一个内容
_EsdDynamicTransformationScript.esd3TagNum1ContentN = $("#zhx_one_job_bottom ul:eq(0) li:eq("+_EsdDynamicTransformationScript.num6+") a:eq(1)");
_EsdDynamicTransformationScript.esd3TagNum2ContentN = $("#zhx_one_job_bottom ul:eq(1) li:eq("+_EsdDynamicTransformationScript.num7+") a:eq(1)");
_EsdDynamicTransformationScript.esd3TagNum3ContentN = $("#zhx_one_job_bottom ul:eq(2) li:eq("+_EsdDynamicTransformationScript.num8+") a:eq(1)");
_EsdDynamicTransformationScript.esd3TagNum4ContentN = $("#zhx_one_job_bottom ul:eq(3) li:eq("+_EsdDynamicTransformationScript.num9+") a:eq(1)");
_EsdDynamicTransformationScript.esd3TagNum5ContentN = $("#zhx_one_job_bottom ul:eq(4) li:eq("+_EsdDynamicTransformationScript.num10+") a:eq(1)");
	
	//第一块
	_EsdDynamicTransformationScript.esd3TagNum1.focus(function (e) {
		
		e = $(this).mouseover();
		$(document).bind("keydown.keydown_1", function (e) {
			if(e.shiftKey&&e.keyCode==9){
				
			}else if (e.keyCode == 9) {
				_EsdDynamicTransformationScript.esd3TagNum1Content1.focus();
				console.log(document.activeElement);
				return false;
			}
		});

	});
	_EsdDynamicTransformationScript.esd3TagNum1.blur(function () {
		$(document).unbind("keydown.keydown_1");
	});

	_EsdDynamicTransformationScript.esd3TagNum1Content1.focus(function () {
		$(document).bind("keydown.keydown_s1", function (e) {
			if (e.shiftKey && e.keyCode == 9) {
				_EsdDynamicTransformationScript.esd3TagNum1.focus();
				return false;
			}
		});
	});
	_EsdDynamicTransformationScript.esd3TagNum1Content1.blur(function () {
		$(document).unbind("keydown.keydown_s1");
	});

	_EsdDynamicTransformationScript.esd3TagNum1ContentN.focus(function () {
		$(document).bind("keydown.keydown_e1", function (e) {
			if(e.shiftKey&&e.keyCode==9){
				
			}else if (e.keyCode == 9) {
				_EsdDynamicTransformationScript.esd3TagNum2.focus();
				return false;
			}
		});
	});
	_EsdDynamicTransformationScript.esd3TagNum1ContentN.blur(function () {
		$(document).unbind("keydown.keydown_e1");
	});
	//第二块
	_EsdDynamicTransformationScript.esd3TagNum2.focus(function (e) {
		e = $(this).mouseover();
		$(document).bind("keydown.keydown_2", function (e) {
			if(e.shiftKey&&e.keyCode==9){
				_EsdDynamicTransformationScript.esd3TagNum1.mouseover();
				_EsdDynamicTransformationScript.esd3TagNum1ContentN.focus();
				return false;
			}else if (e.keyCode == 9) {
				_EsdDynamicTransformationScript.esd3TagNum2Content1.focus();
				console.log(document.activeElement);
				return false;
			}
		});

	});
	_EsdDynamicTransformationScript.esd3TagNum2.blur(function () {
		$(document).unbind("keydown.keydown_2");
	});

	_EsdDynamicTransformationScript.esd3TagNum2Content1.focus(function () {
		$(document).bind("keydown.keydown_s2", function (e) {
			if (e.shiftKey && e.keyCode == 9) {
				_EsdDynamicTransformationScript.esd3TagNum2.focus();
				return false;
			}
		});
	});

	_EsdDynamicTransformationScript.esd3TagNum2Content1.blur(function () {
		$(document).unbind("keydown.keydown_s2");
	});

	_EsdDynamicTransformationScript.esd3TagNum2ContentN.focus(function () {
		$(document).bind("keydown.keydown_e2", function (e) {
			if(e.shiftKey&&e.keyCode==9){
				
			}else if (e.keyCode == 9) {
				_EsdDynamicTransformationScript.esd3TagNum3.focus();
				return false;
			}
		});
	});
	_EsdDynamicTransformationScript.esd3TagNum2ContentN.blur(function () {
		$(document).unbind("keydown.keydown_e2");
	});
	
	//第三块
	_EsdDynamicTransformationScript.esd3TagNum3.focus(function (e) {
		e = $(this).mouseover();
		$(document).bind("keydown.keydown_3", function (e) {
			if(e.shiftKey&&e.keyCode==9){
				_EsdDynamicTransformationScript.esd3TagNum2.mouseover();
				_EsdDynamicTransformationScript.esd3TagNum2ContentN.focus();
				return false;
			}else if (e.keyCode == 9) {
				_EsdDynamicTransformationScript.esd3TagNum3Content1.focus();
				console.log(document.activeElement);
				return false;
			}
		});

	});
	_EsdDynamicTransformationScript.esd3TagNum3.blur(function () {
		$(document).unbind("keydown.keydown_3");
	});

	_EsdDynamicTransformationScript.esd3TagNum3Content1.focus(function () {
		$(document).bind("keydown.keydown_s3", function (e) {
			if (e.shiftKey && e.keyCode == 9) {
				_EsdDynamicTransformationScript.esd3TagNum3.focus();
				return false;
			}
		});
	});

	_EsdDynamicTransformationScript.esd3TagNum3Content1.blur(function () {
		$(document).unbind("keydown.keydown_s3");
	});

	_EsdDynamicTransformationScript.esd3TagNum3ContentN.focus(function () {
		$(document).bind("keydown.keydown_e3", function (e) {
			if(e.shiftKey&&e.keyCode==9){
				
			}else if (e.keyCode == 9) {
				_EsdDynamicTransformationScript.esd3TagNum4.focus();
				return false;
			}
		});
	});
	_EsdDynamicTransformationScript.esd3TagNum3ContentN.blur(function () {
		$(document).unbind("keydown.keydown_e3");
	});
	
	//第四块
	_EsdDynamicTransformationScript.esd3TagNum4.focus(function (e) {
		e = $(this).mouseover();
		$(document).bind("keydown.keydown_4", function (e) {
			if(e.shiftKey&&e.keyCode==9){
				_EsdDynamicTransformationScript.esd3TagNum3.mouseover();
				_EsdDynamicTransformationScript.esd3TagNum3ContentN.focus();
				return false;
			}else if (e.keyCode == 9) {
				_EsdDynamicTransformationScript.esd3TagNum4Content1.focus();
				console.log(document.activeElement);
				return false;
			}
		});

	});
	_EsdDynamicTransformationScript.esd3TagNum4.blur(function () {
		$(document).unbind("keydown.keydown_4");
	});

	_EsdDynamicTransformationScript.esd3TagNum4Content1.focus(function () {
		$(document).bind("keydown.keydown_s4", function (e) {
			if (e.shiftKey && e.keyCode == 9) {
				_EsdDynamicTransformationScript.esd3TagNum4.focus();
				return false;
			}
		});
	});

	_EsdDynamicTransformationScript.esd3TagNum4Content1.blur(function () {
		$(document).unbind("keydown.keydown_s4");
	});

	_EsdDynamicTransformationScript.esd3TagNum4ContentN.focus(function () {
		$(document).bind("keydown.keydown_e4", function (e) {
			if(e.shiftKey&&e.keyCode==9){
				
			}else if (e.keyCode == 9) {
				_EsdDynamicTransformationScript.esd3TagNum5.focus();
				return false;
			}
		});
	});
	_EsdDynamicTransformationScript.esd3TagNum4ContentN.blur(function () {
		$(document).unbind("keydown.keydown_e4");
	});
	
	//第五块
	_EsdDynamicTransformationScript.esd3TagNum5.focus(function (e) {
		e = $(this).mouseover();
		$(document).bind("keydown.keydown_5", function (e) {
			if(e.shiftKey&&e.keyCode==9){
				_EsdDynamicTransformationScript.esd3TagNum4.mouseover();
				_EsdDynamicTransformationScript.esd3TagNum4ContentN.focus();
				return false;
			}else if (e.keyCode == 9) {
				_EsdDynamicTransformationScript.esd3TagNum5Content1.focus();
				console.log(document.activeElement);
				return false;
			}
		});

	});
	_EsdDynamicTransformationScript.esd3TagNum5.blur(function () {
		$(document).unbind("keydown.keydown_5");
	});
	
	
//第四部分	
	
	
	
	
	
	

//第五部分

	//三层  


	//各个选项名称对应的内容数量
_EsdDynamicTransformationScript.num13 = $("#zhx_three_xglj_bottom_bottom ul:eq(0) li").length-1;
_EsdDynamicTransformationScript.num14 = $("#zhx_three_xglj_bottom_bottom ul:eq(1) li").length-1;
_EsdDynamicTransformationScript.num15 = $("#zhx_three_xglj_bottom_bottom ul:eq(2) li").length-1;
	
	//各个选项名称
_EsdDynamicTransformationScript.esd5TagNum1 = $("#zhx_three_xglj_bottom_top ul li:eq(0) a");
_EsdDynamicTransformationScript.esd5TagNum2 = $("#zhx_three_xglj_bottom_top ul li:eq(1) a");
_EsdDynamicTransformationScript.esd5TagNum3 = $("#zhx_three_xglj_bottom_top ul li:eq(2) a");
	
	//各个选项中的第一个内容
_EsdDynamicTransformationScript.esd5TagNum1Content1 = $("#zhx_three_xglj_bottom_bottom ul:eq(0) li:eq(0) a");
_EsdDynamicTransformationScript.esd5TagNum2Content1 = $("#zhx_three_xglj_bottom_bottom ul:eq(1) li:eq(0) a");
_EsdDynamicTransformationScript.esd5TagNum3Content1 = $("#zhx_three_xglj_bottom_bottom ul:eq(2) li:eq(0) a");
	
	//各个选项中的最后一个内容
_EsdDynamicTransformationScript.esd5TagNum1ContentN = $("#zhx_three_xglj_bottom_bottom ul:eq(0) li:eq("+_EsdDynamicTransformationScript.num13+") a");
_EsdDynamicTransformationScript.esd5TagNum2ContentN = $("#zhx_three_xglj_bottom_bottom ul:eq(1) li:eq("+_EsdDynamicTransformationScript.num14+") a");
_EsdDynamicTransformationScript.esd5TagNum3ContentN = $("#zhx_three_xglj_bottom_bottom ul:eq(2) li:eq("+_EsdDynamicTransformationScript.num15+") a");
	
	//底部iframe块
_EsdDynamicTransformationScript.esd6Iframe = document.getElementsByTagName("iframe")[5];
_EsdDynamicTransformationScript.esd6IframeFirstA = document.getElementsByTagName("iframe")[5].contentWindow.document.getElementsByTagName("a")[0];
	
	//第一块
	_EsdDynamicTransformationScript.esd5TagNum1.focus(function (e) {
		
		e = $(this).mouseover();
		$(document).bind("keydown.keydown_1", function (e) {
			if(e.shiftKey&&e.keyCode==9){
				
			}else if (e.keyCode == 9) {
				_EsdDynamicTransformationScript.esd5TagNum1Content1.focus();
				console.log(document.activeElement);
				return false;
			}
		});

	});
	_EsdDynamicTransformationScript.esd5TagNum1.blur(function () {
		$(document).unbind("keydown.keydown_1");
	});

	_EsdDynamicTransformationScript.esd5TagNum1Content1.focus(function () {
		$(document).bind("keydown.keydown_s1", function (e) {
			if (e.shiftKey && e.keyCode == 9) {
				_EsdDynamicTransformationScript.esd5TagNum1.focus();
				return false;
			}
		});
	});
	_EsdDynamicTransformationScript.esd5TagNum1Content1.blur(function () {
		$(document).unbind("keydown.keydown_s1");
	});

	_EsdDynamicTransformationScript.esd5TagNum1ContentN.focus(function () {
		$(document).bind("keydown.keydown_e1", function (e) {
			if(e.shiftKey&&e.keyCode==9){
				
			}else if (e.keyCode == 9) {
				_EsdDynamicTransformationScript.esd5TagNum2.focus();
				return false;
			}
		});
	});
	_EsdDynamicTransformationScript.esd5TagNum1ContentN.blur(function () {
		$(document).unbind("keydown.keydown_e1");
	});
	//第二块
	_EsdDynamicTransformationScript.esd5TagNum2.focus(function (e) {
		e = $(this).mouseover();
		$(document).bind("keydown.keydown_2", function (e) {
			if(e.shiftKey&&e.keyCode==9){
				_EsdDynamicTransformationScript.esd5TagNum1.mouseover();
				_EsdDynamicTransformationScript.esd5TagNum1ContentN.focus();
				return false;
			}else if (e.keyCode == 9) {
				_EsdDynamicTransformationScript.esd5TagNum2Content1.focus();
				console.log(document.activeElement);
				return false;
			}
		});

	});
	_EsdDynamicTransformationScript.esd5TagNum2.blur(function () {
		$(document).unbind("keydown.keydown_2");
	});

	_EsdDynamicTransformationScript.esd5TagNum2Content1.focus(function () {
		$(document).bind("keydown.keydown_s2", function (e) {
			if (e.shiftKey && e.keyCode == 9) {
				_EsdDynamicTransformationScript.esd5TagNum2.focus();
				return false;
			}
		});
	});

	_EsdDynamicTransformationScript.esd5TagNum2Content1.blur(function () {
		$(document).unbind("keydown.keydown_s2");
	});

	_EsdDynamicTransformationScript.esd5TagNum2ContentN.focus(function () {
		$(document).bind("keydown.keydown_e2", function (e) {
			if(e.shiftKey&&e.keyCode==9){
				
			}else if (e.keyCode == 9) {
				_EsdDynamicTransformationScript.esd5TagNum3.focus();
				return false;
			}
		});
	});
	_EsdDynamicTransformationScript.esd5TagNum2ContentN.blur(function () {
		$(document).unbind("keydown.keydown_e2");
	});
	
	//第三块
	_EsdDynamicTransformationScript.esd5TagNum3.focus(function (e) {
		e = $(this).mouseover();
		$(document).bind("keydown.keydown_3", function (e) {
			if(e.shiftKey&&e.keyCode==9){
				_EsdDynamicTransformationScript.esd5TagNum2.mouseover();
				_EsdDynamicTransformationScript.esd5TagNum2ContentN.focus();
				return false;
			}else if (e.keyCode == 9) {
				_EsdDynamicTransformationScript.esd5TagNum3Content1.focus();
				console.log(document.activeElement);
				return false;
			}
		});

	});
	_EsdDynamicTransformationScript.esd5TagNum3.blur(function () {
		$(document).unbind("keydown.keydown_3");
	});
	
	_EsdDynamicTransformationScript.esd5TagNum3ContentN.focus(function () {
		$(document).bind("keydown.keydown_e3", function (e) {
			if(e.shiftKey&&e.keyCode==9){
				
			}else if (e.keyCode == 9) {
				$(_EsdDynamicTransformationScript.esd6Iframe).focus();
				return false;
			}
		});
	});
	_EsdDynamicTransformationScript.esd5TagNum3ContentN.blur(function () {
		$(document).unbind("keydown.keydown_e3");
	});
	
	
	

	
	
	
	
	
	
}
/**
 * 共通底部处理
 */
/**
 * 文本链接 a
 */
//	_EsdDynamicTransformationScript.navBlock = {}; //定义区域跳转类
//	_EsdDynamicTransformationScript.navBlock.debug = true; //是否是调试模式，调试模式有红边线，非调试模式关闭红边框
//	//定义跳转 使用jquery选择器语法
//	_EsdDynamicTransformationScript.navBlock.selector = {};

	
	
if(location.href=="http://jldrc.jl.gov.cn/" || location.href=="http://jldrc.jl.gov.cn/index.html"){
	
	//定义跳转 使用jquery选择器语法
	//主要修改部分把网站对应的选择器赋值给相应的变量。或用jquery把默认的id复制给网站的元素****************************此处重要位置修改
	$(".zhx_head_box").attr("id","header");
	_EsdDynamicTransformationScript.navBlock.selector.top = "#header";
	$("#zhx_box0 .zhx_nav_box ul").attr("id","nav");
	_EsdDynamicTransformationScript.navBlock.selector.nav = "#nav";
	$("iframe:eq(5)").attr("id","footer");
	_EsdDynamicTransformationScript.navBlock.selector.footer = "#footer";
	$("#zhx_box0>div").attr("id","main");
	_EsdDynamicTransformationScript.navBlock.selector.main = "#main";
	_EsdDynamicTransformationScript.navBlock.selector.left = "#left";
	_EsdDynamicTransformationScript.navBlock.selector.right = "#right";
	_EsdDynamicTransformationScript.navBlock.selector.content = "#content";
	//给栏目的class属性添加navBlock值来标识这是需要切的栏目区块。
	$("#zhx_box0 .zhx_nav_box .zhx_nav .zhx_nav_lunbo_box").addClass("navBlock");
	$("#zhx_box0 .zhx_nav_box .zhx_nav .zhx_nav_li1").addClass("navBlock");
	$("#zhx_box0 .zhx_nav_box .zhx_nav .zhx_nav_li2").addClass("navBlock");
	$("#zhx_box0 .zhx_nav_box .zhx_nav .zhx_nav_li3").addClass("navBlock");
	$("#zhx_box0 .zhx_nav_box .zhx_nav .zhx_nav_li4").addClass("navBlock");
	$("#zhx_box0 .zhx_one_box .zhx_one_pic").addClass("navBlock");
	$("#zhx_box0 .zhx_one_box .zhx_one_job").addClass("navBlock");
	$("#zhx_box0 .zhx_one_box .zhx_one_org").addClass("navBlock");
	$("#zhx_box0 .zhx_two_box .zhx_two_zmhd").addClass("navBlock");
	$("#zhx_box0 .zhx_two_box .zhx_two_zfxxgk").addClass("navBlock");
	$("#zhx_box0 .zhx_two_box .zhx_two_zyxxzczz").addClass("navBlock");
	$("#zhx_box0 .zhx_three_box .zhx_three_jgcs").addClass("navBlock");
	$("#zhx_box0 .zhx_three_box .zhx_three_xglj").addClass("navBlock");
	_EsdDynamicTransformationScript.navBlock.selector.activate = ".navBlock"; //激活的采用class因为会激活多个
	
}
	
if(location.href=="http://jldrc.jl.gov.cn/zmhd/ldxx/" || location.href=="http://jldrc.jl.gov.cn/zmhd/jyxc/" || location.href=="http://jldrc.jl.gov.cn/zmhd/jyxc/"){
	//领导信箱
	$(".zhx_head_box").attr("id","header");
	if(document.getElementById("header")){
		
	}else{
		$(document.getElementsByTagName("iframe")[0]).attr("id","header");
	}
	_EsdDynamicTransformationScript.navBlock.selector.top = "#header";
	_EsdDynamicTransformationScript.navBlock.selector.nav = "#nav";
	$("iframe:last").attr("id","footer");
	_EsdDynamicTransformationScript.navBlock.selector.footer = "#footer";
	$(".cr-main-rainbow").attr("id","main");
	_EsdDynamicTransformationScript.navBlock.selector.main = "#main";
	$(".left_secondlist_lv").attr("id","left");
	_EsdDynamicTransformationScript.navBlock.selector.left = "#left";
	$(".right_secondlist_lv").attr("id","right");
	_EsdDynamicTransformationScript.navBlock.selector.right = "#right";

	_EsdDynamicTransformationScript.navBlock.selector.content = "#content";
	//给栏目的class属性添加navBlock值来标识这是需要切的栏目区块。
	$(".cr-main-rainbow ul").addClass("navBlock");
	$(".cr-main-rainbow .mian-1").addClass("navBlock");
	$(".cr-main-rainbow table").addClass("navBlock");
	_EsdDynamicTransformationScript.navBlock.selector.activate = ".navBlock"; //激活的采用class因为会激活多个
}	
	




/**
 * 区域导航、调试开关
 */

$(document).bind("keydown.keydown_9001", function(e) {
	if (e.shiftKey && e.keyCode == 20) {
		$("*").focus(function() {
			$(this).css({
				"outline" : "2px dashed red"
			});
		});
		$("*").blur(function() {
			$(this).css({
				"outline" : "0px black"
			});
		});
	}
});

	/**
	 * 说明： 区域跳转+区块跳转
	 * 区域跳转包括：头部区域（top），导航区域(nav)，主要区域(main){左侧区域，中间区域，右侧区域}，底部区域(footer)。
	 * 区块跳转包括：也叫栏目跳转，是对主要区域(main)内进行栏目的细分，用于盲人快速找到感兴趣的栏目。
	 * 
	 */
	// 加载必要支持库，嵌入了mousetrap代码，如需升级版本删除下载新版本后单独加载即可
	/* mousetrap v1.6.5 craig.is/killing/mice */
	(function(q,u,c){function v(a,b,g){a.addEventListener?a.addEventListener(b,g,!1):a.attachEvent("on"+b,g)}function z(a){if("keypress"==a.type){var b=String.fromCharCode(a.which);a.shiftKey||(b=b.toLowerCase());return b}return n[a.which]?n[a.which]:r[a.which]?r[a.which]:String.fromCharCode(a.which).toLowerCase()}function F(a){var b=[];a.shiftKey&&b.push("shift");a.altKey&&b.push("alt");a.ctrlKey&&b.push("ctrl");a.metaKey&&b.push("meta");return b}function w(a){return"shift"==a||"ctrl"==a||"alt"==a||
	"meta"==a}function A(a,b){var g,d=[];var e=a;"+"===e?e=["+"]:(e=e.replace(/\+{2}/g,"+plus"),e=e.split("+"));for(g=0;g<e.length;++g){var m=e[g];B[m]&&(m=B[m]);b&&"keypress"!=b&&C[m]&&(m=C[m],d.push("shift"));w(m)&&d.push(m)}e=m;g=b;if(!g){if(!p){p={};for(var c in n)95<c&&112>c||n.hasOwnProperty(c)&&(p[n[c]]=c)}g=p[e]?"keydown":"keypress"}"keypress"==g&&d.length&&(g="keydown");return{key:m,modifiers:d,action:g}}function D(a,b){return null===a||a===u?!1:a===b?!0:D(a.parentNode,b)}function d(a){function b(a){a=
	a||{};var b=!1,l;for(l in p)a[l]?b=!0:p[l]=0;b||(x=!1)}function g(a,b,t,f,g,d){var l,E=[],h=t.type;if(!k._callbacks[a])return[];"keyup"==h&&w(a)&&(b=[a]);for(l=0;l<k._callbacks[a].length;++l){var c=k._callbacks[a][l];if((f||!c.seq||p[c.seq]==c.level)&&h==c.action){var e;(e="keypress"==h&&!t.metaKey&&!t.ctrlKey)||(e=c.modifiers,e=b.sort().join(",")===e.sort().join(","));e&&(e=f&&c.seq==f&&c.level==d,(!f&&c.combo==g||e)&&k._callbacks[a].splice(l,1),E.push(c))}}return E}function c(a,b,c,f){k.stopCallback(b,
	b.target||b.srcElement,c,f)||!1!==a(b,c)||(b.preventDefault?b.preventDefault():b.returnValue=!1,b.stopPropagation?b.stopPropagation():b.cancelBubble=!0)}function e(a){"number"!==typeof a.which&&(a.which=a.keyCode);var b=z(a);b&&("keyup"==a.type&&y===b?y=!1:k.handleKey(b,F(a),a))}function m(a,g,t,f){function h(c){return function(){x=c;++p[a];clearTimeout(q);q=setTimeout(b,1E3)}}function l(g){c(t,g,a);"keyup"!==f&&(y=z(g));setTimeout(b,10)}for(var d=p[a]=0;d<g.length;++d){var e=d+1===g.length?l:h(f||
	A(g[d+1]).action);n(g[d],e,f,a,d)}}function n(a,b,c,f,d){k._directMap[a+":"+c]=b;a=a.replace(/\s+/g," ");var e=a.split(" ");1<e.length?m(a,e,b,c):(c=A(a,c),k._callbacks[c.key]=k._callbacks[c.key]||[],g(c.key,c.modifiers,{type:c.action},f,a,d),k._callbacks[c.key][f?"unshift":"push"]({callback:b,modifiers:c.modifiers,action:c.action,seq:f,level:d,combo:a}))}var k=this;a=a||u;if(!(k instanceof d))return new d(a);k.target=a;k._callbacks={};k._directMap={};var p={},q,y=!1,r=!1,x=!1;k._handleKey=function(a,
	d,e){var f=g(a,d,e),h;d={};var k=0,l=!1;for(h=0;h<f.length;++h)f[h].seq&&(k=Math.max(k,f[h].level));for(h=0;h<f.length;++h)f[h].seq?f[h].level==k&&(l=!0,d[f[h].seq]=1,c(f[h].callback,e,f[h].combo,f[h].seq)):l||c(f[h].callback,e,f[h].combo);f="keypress"==e.type&&r;e.type!=x||w(a)||f||b(d);r=l&&"keydown"==e.type};k._bindMultiple=function(a,b,c){for(var d=0;d<a.length;++d)n(a[d],b,c)};v(a,"keypress",e);v(a,"keydown",e);v(a,"keyup",e)}if(q){var n={8:"backspace",9:"tab",13:"enter",16:"shift",17:"ctrl",
	18:"alt",20:"capslock",27:"esc",32:"space",33:"pageup",34:"pagedown",35:"end",36:"home",37:"left",38:"up",39:"right",40:"down",45:"ins",46:"del",91:"meta",93:"meta",224:"meta"},r={106:"*",107:"+",109:"-",110:".",111:"/",186:";",187:"=",188:",",189:"-",190:".",191:"/",192:"`",219:"[",220:"\\",221:"]",222:"'"},C={"~":"`","!":"1","@":"2","#":"3",$:"4","%":"5","^":"6","&":"7","*":"8","(":"9",")":"0",_:"-","+":"=",":":";",'"':"'","<":",",">":".","?":"/","|":"\\"},B={option:"alt",command:"meta","return":"enter",
	escape:"esc",plus:"+",mod:/Mac|iPod|iPhone|iPad/.test(navigator.platform)?"meta":"ctrl"},p;for(c=1;20>c;++c)n[111+c]="f"+c;for(c=0;9>=c;++c)n[c+96]=c.toString();d.prototype.bind=function(a,b,c){a=a instanceof Array?a:[a];this._bindMultiple.call(this,a,b,c);return this};d.prototype.unbind=function(a,b){return this.bind.call(this,a,function(){},b)};d.prototype.trigger=function(a,b){if(this._directMap[a+":"+b])this._directMap[a+":"+b]({},a);return this};d.prototype.reset=function(){this._callbacks={};
	this._directMap={};return this};d.prototype.stopCallback=function(a,b){if(-1<(" "+b.className+" ").indexOf(" mousetrap ")||D(b,this.target))return!1;if("composedPath"in a&&"function"===typeof a.composedPath){var c=a.composedPath()[0];c!==a.target&&(b=c)}return"INPUT"==b.tagName||"SELECT"==b.tagName||"TEXTAREA"==b.tagName||b.isContentEditable};d.prototype.handleKey=function(){return this._handleKey.apply(this,arguments)};d.addKeycodes=function(a){for(var b in a)a.hasOwnProperty(b)&&(n[b]=a[b]);p=null};
	d.init=function(){var a=d(u),b;for(b in a)"_"!==b.charAt(0)&&(d[b]=function(b){return function(){return a[b].apply(a,arguments)}}(b))};d.init();q.Mousetrap=d;"undefined"!==typeof module&&module.exports&&(module.exports=d);"function"===typeof define&&define.amd&&define(function(){return d})}})("undefined"!==typeof window?window:null,"undefined"!==typeof window?document:null);

	// 嵌入了mousetrap代码结束


	_EsdDynamicTransformationScript.navBlock.debug = true; // 是否是调试模式，调试模式有红边线，非调试模式关闭红边框


	_EsdDynamicTransformationScript.navBlock.selector.activate = ".navBlock"; // 激活的采用class因为会激活多个

	// 快捷键定义区
	_EsdDynamicTransformationScript.navBlock.key = {};
	/*
	 * 区域跳转JS 插件支持：jquery、mousetrap
	 * 功能：为避免与浏览器快捷键冲突默认全部采用3+1组合键（alt+ctrl+shift）+自定义键 头部区域跳转
	 * alt+ctrl+shift+T(top) 导航区域跳转 alt+ctrl+shift+N(nav) 主要区域跳转
	 * alt+ctrl+shift+M(main) 左侧区域跳转 alt+ctrl+shift+L(left) 右侧区域跳转
	 * alt+ctrl+shift+R(right) 正文区域跳转 alt+ctrl+shift+C(content) 底部区域跳转
	 * alt+ctrl+shift+F(footer) 栏目导航正跳转 alt+ctrl+shift+D(up) 栏目导航逆跳转
	 * alt+ctrl+shift+U(down);
	 */
	_EsdDynamicTransformationScript.navBlock.key.top = "alt+1"; // (top)
	_EsdDynamicTransformationScript.navBlock.key.nav = "alt+2"; // (nav)
	_EsdDynamicTransformationScript.navBlock.key.main = "alt+3"; // (main)
	_EsdDynamicTransformationScript.navBlock.key.content = "alt+4"; // (content)
	_EsdDynamicTransformationScript.navBlock.key.left = "alt+5"; // (left)
	_EsdDynamicTransformationScript.navBlock.key.right = "alt+6"; // (right)
	_EsdDynamicTransformationScript.navBlock.key.footer = "alt+7"; // (footer)
	_EsdDynamicTransformationScript.navBlock.key.down = "alt+8"; // (down)
	_EsdDynamicTransformationScript.navBlock.key.up = "alt+9"; // (up);


	// 以下变量主要用于区块跳转
	_EsdDynamicTransformationScript.navBlock.sIndex = -1; // 当前栏目下标
	_EsdDynamicTransformationScript.navBlock.maxIndex = -1; // 保存目前所有class="navBlock"的区域块总数量，栏目总量下标。
	_EsdDynamicTransformationScript.navBlock.minIndex = 0; // 栏目数量起始下标

	// 主要代码区域

	// 导航跳转
	_EsdDynamicTransformationScript.navBlock.keyShowSelect = function (i) {
	    $(_EsdDynamicTransformationScript.navBlock.selector.activate).each(function (index, el) {
	        if (i == index) {
	            _EsdDynamicTransformationScript.navBlock.debugView(el);
	            $(el).find("a").each(function (i, e) {
	                if (i == 0) {
	                    $(e).focus();
	                }
	            });

	        }
	    });
	}
	
	// 获取所有class=navBlock的区域的总数量，初始化轮训所有需要跳转的块
	$(_EsdDynamicTransformationScript.navBlock.selector.activate).each(function (index, ehx) {
	    _EsdDynamicTransformationScript.navBlock.maxIndex++;
	});

	// 前进
	Mousetrap.bind(_EsdDynamicTransformationScript.navBlock.key.down, function () { // down
	    if (_EsdDynamicTransformationScript.navBlock.sIndex < _EsdDynamicTransformationScript.navBlock.maxIndex) {
	        _EsdDynamicTransformationScript.navBlock.sIndex++;
	        _EsdDynamicTransformationScript.navBlock.keyShowSelect(_EsdDynamicTransformationScript.navBlock.sIndex);
	    }
	    return false;
	});
	// 后退
	Mousetrap.bind(_EsdDynamicTransformationScript.navBlock.key.up, function () { // up
	    if (_EsdDynamicTransformationScript.navBlock.sIndex > _EsdDynamicTransformationScript.navBlock.minIndex) {
	        _EsdDynamicTransformationScript.navBlock.sIndex--;
	        _EsdDynamicTransformationScript.navBlock.keyShowSelect(_EsdDynamicTransformationScript.navBlock.sIndex);
	    }
	    return false;
	});

	// 快捷键功能区域
	// 跳转到头部
	Mousetrap.bind(_EsdDynamicTransformationScript.navBlock.key.top, function () {
	    _EsdDynamicTransformationScript.navBlock.keySelectScroll(_EsdDynamicTransformationScript.navBlock.selector.top);
	    return false;
	});
	// 跳转到导航
	Mousetrap.bind(_EsdDynamicTransformationScript.navBlock.key.nav, function () {
	    _EsdDynamicTransformationScript.navBlock.keySelectScroll(_EsdDynamicTransformationScript.navBlock.selector.nav);
	    return false;
	});
	// 跳转到底部
	Mousetrap.bind(_EsdDynamicTransformationScript.navBlock.key.footer, function () {
	    _EsdDynamicTransformationScript.navBlock.keySelectScroll(_EsdDynamicTransformationScript.navBlock.selector.footer);
	    return false;
	});
	// 跳转到主要区域
	Mousetrap.bind(_EsdDynamicTransformationScript.navBlock.key.main, function () {
	    _EsdDynamicTransformationScript.navBlock.keySelectScroll(_EsdDynamicTransformationScript.navBlock.selector.main);
	    return false;
	});
	// 跳转到左区域
	Mousetrap.bind(_EsdDynamicTransformationScript.navBlock.key.left, function () {
	    _EsdDynamicTransformationScript.navBlock.keySelectScroll(_EsdDynamicTransformationScript.navBlock.selector.left);
	    return false;
	});

	// 跳转到右区域
	Mousetrap.bind(_EsdDynamicTransformationScript.navBlock.key.right, function () {
	    _EsdDynamicTransformationScript.navBlock.keySelectScroll(_EsdDynamicTransformationScript.navBlock.selector.right);
	    return false;
	});
	// 跳转到正文区域
	Mousetrap.bind(_EsdDynamicTransformationScript.navBlock.key.content, function () {
	    _EsdDynamicTransformationScript.navBlock.keySelectScroll(_EsdDynamicTransformationScript.navBlock.selector.content);
	    return false;
	});

	// 特定区域跳转
	_EsdDynamicTransformationScript.navBlock.keySelectScroll = function (id) {
	    if ($(id).length > 0) {
	        _EsdDynamicTransformationScript.navBlock.debugView(id);
	        $(id).find("a").each(function (index) {
	            if (index == 0) {
	                $(this).focus();
	            }
	        });
	    } else {}

	}
	if (_EsdDynamicTransformationScript.navBlock.debug == true) {
	    // 如果开启调试模式，添加调试绘制矩形边线
	    $("body").append("<div id='show_top' class='lineshow'></div>");
	    $("body").append("<div id='show_bottom' class='lineshow'></div>");
	    $("body").append("<div id='show_left' class='lineshow'></div>");
	    $("body").append("<div id='show_right' class='lineshow'></div>");
	    $(".lineshow").css({
	        "display": "none"
	    });
	}
	// 开启调试模式后会显示红边
	_EsdDynamicTransformationScript.navBlock.debugView = function (e) {
	    if (_EsdDynamicTransformationScript.navBlock.debug == true) {
	        var x = $(e).offset();
	        var w = parseInt($(e).css("width")); ;
	        var h = parseInt($(e).css("height"));
	        $("#show_top").css({
	            "z-index": "9999",
	            "border": "red 2px solid",
	            "position": "absolute",
	            "top": x.top,
	            "left": x.left,
	            "width": w,
	            "height": "0px"
	        });
	        $("#show_bottom").css({
	            "z-index": "9999",
	            "border": "red 2px solid",
	            "position": "absolute",
	            "top": x.top + h,
	            "left": x.left,
	            "width": w,
	            "height": "0px"
	        });
	        $("#show_left").css({
	            "z-index": "9999",
	            "border": "red 2px solid",
	            "position": "absolute",
	            "top": x.top,
	            "left": x.left,
	            "width": "0px",
	            "height": h
	        });
	        $("#show_right").css({
	            "z-index": "9999",
	            "border": "red 2px solid",
	            "position": "absolute",
	            "top": x.top,
	            "left": x.left + w,
	            "width": "0px",
	            "height": h
	        });
	        $("html,body").animate({
	            scrollTop: $("#show_top").offset().top
	        }, 200);
	        $(".lineshow").css({
	            "display": "block"
	        });
	    }
	}
};
/**
 * 主入口方法
 */



if (window.jQuery == undefined) {
	var wzaInitInterval = setInterval(function(){	
		if(document.body!=null){
			clearInterval(wzaInitInterval);
			document.body.onload = function(){
				var esdJquery = document.createElement("script");
				esdJquery.setAttribute("type", "text/javascript");
				esdJquery.setAttribute("src", window.location.origin + "/wza/bwscript/jquery-1.12.4.min.js");
				esdJquery.setAttribute("charset", "utf-8");
				esdJquery.setAttribute("id", "ESDWebAppInnerIframe");
				esdJquery.onload = function () {
					_EsdDynamicTransformationFunction(jQuery);
				};
				document.head.appendChild(esdJquery);
			};	
		}
	}, 10);
} else {
	jQuery(function(){
		_EsdDynamicTransformationFunction(jQuery);
	})
	
}
